// 接口  传递的必须是对象
interface Girl {
  name: string;
  age: number;
  bust: number;
  waistline?: number;
  [propname: string]: any;
  say(): string;
}

interface Teacher extends Girl {
  teach(): string
}

class xjj_class implements Girl {
  name = 'ajj'
  age = 12
  bust = 68
  say() {
    return `my name is ${this.name}`
  }
}



const xjj_eg = new xjj_class()
console.log(xjj_eg.say())
const djGirl = {
  name: 'xdj',
  age: 21,
  bust: 89,
  waistline: 32,
  say() {
    return `my name is ${this.name}`
  }
}
const xjGirl = {
  name: 'xxj',
  age: 22,
  bust: 99,
  sex: '女',
  say() {
    return `my name is ${this.name}`
  },
  teach(){
    return `my teach is Math`
  }
}

const screenResume = (girl: Girl) => {
  girl.age < 24 && girl.bust >= 90 && console.log(girl.name + "进入面试");
  (girl.age > 24 || girl.bust < 90) && console.log(girl.name + "你被淘汰");
}
const getResume = (girl: Teacher) => {
  console.log(girl.say())
  console.log(girl.teach())
}

screenResume(djGirl)

screenResume(xjGirl)
getResume(xjGirl)